package com.bpc.cs.dto;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;

import com.bpc.cs.constant.DBConstant;

/**
 * @author   phan_tp
 * @datetime Nov 30, 2012 : 2:25:49 PM
 */

@Entity
@Table (name = DBConstant.TBL_SCORING_FACTOR_CHOICE)
public class FactorChoiceDTO {
	@Id
	@SequenceGenerator(name = "generator_factorchoice", sequenceName = "factorchoice_id_seq",
					   catalog = "CREDIT_SCORING", schema = "SCREDIT_SCORING", allocationSize = 1)
	@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "generator_factorchoice")
	@Column (name = DBConstant.COL_SFC_ID, unique = true, nullable = false)
	private int factorChoiceID;

	@Column (name = DBConstant.COL_SFC_FACTOR_CHOICE, unique = false, nullable = false)
	private String factorChoice;

	@ManyToOne
	@JoinColumn (name = DBConstant.COL_SFC_SR_ID)
	private RuleDTO ruleDTO;

	@Column (name = DBConstant.COL_SFC_SCORE, unique = false, nullable = false)
	private int score;

	/**
	 * @return the factorChoiceID
	 */
	public int getFactorChoiceID() {
		return factorChoiceID;
	}

	/**
	 * @param factorChoiceID the factorChoiceID to set
	 */
	public void setFactorChoiceID(int factorChoiceID) {
		this.factorChoiceID = factorChoiceID;
	}

	/**
	 * @return the caseID
	 */
	public String getFactorChoice() {
		return factorChoice;
	}

	/**
	 * @param String factorChoice
	 */
	public void setFactorChoice(String factorChoice) {
		this.factorChoice = factorChoice;
	}

	/**
	 * @return the score
	 */
	public int getScore() {
		return score;
	}

	/**
	 * @param score the score to set
	 */
	public void setScore(int score) {
		this.score = score;
	}

	/**
	 * @return the ruleDTO
	 */
	public RuleDTO getRuleDTO() {
		return ruleDTO;
	}

	/**
	 * @param RuleDTO the ruleDTO to set
	 */
	public void setRuleDTO(RuleDTO ruleDTO) {
		this.ruleDTO = ruleDTO;
	}

}
